package com.etlmaster.executor.steps.rowprocessor;

import java.util.Map;

import com.etlmaster.executor.StepMeta;
import freemarker.core.FreeMarkerTemplate;
/**
 * @author Larry
 * @copyright Larry@etlMaster
 * @since 2017-09-10
 */
public class RowProcessorUtil {
	public static void genJson(String pluginName,Map<String,String> data,StepMeta meta){
		String reader=FreeMarkerTemplate.getFpl(pluginName, data);
		if(reader==null){
			meta.log("ERROR","生成读取hivereadplugin error!");
		}else{
			meta.log("INFO","生成reader配置成功");
		}
		meta.getStepState().getReturnValue().put("readerjobconf",reader);
		
	}

}
